//
//  DinnerViewController.m
//  CityUCanteen
//
//  Created by Sierra on 2018/3/30.
//  Copyright © 2018年 iFlytek. All rights reserved.
//

#import "DinnerViewController.h"

@interface DinnerViewController ()

@end

@implementation DinnerViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.title = @"Dinner";
}


- (IBAction)didClickDinnerBtnAction:(id)sender {
}


- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}


#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
    id theSegue = segue.destinationViewController;
    [theSegue setValue:@"Dinner" forKey:@"tempData1"];
    
    if([segue.identifier isEqualToString:@"dinnerToOrder1"]) //"passValueToView2"是SEGUE连线的标识
    {
        [theSegue setValue:@"Baked Chicken Rice" forKey:@"tempData2"];
        [theSegue setValue:@"21" forKey:@"tempData3"];
    }
    else if ([segue.identifier isEqualToString:@"dinnerToOrder2"])
    {
        [theSegue setValue:@"Mushroom & Chicken Steamed Rice" forKey:@"tempData2"];
        [theSegue setValue:@"20" forKey:@"tempData3"];
    }
    else
    {
        [theSegue setValue:@"Spicy Tofu Rice" forKey:@"tempData2"];
        [theSegue setValue:@"16" forKey:@"tempData3"];
        
    }
}


@end
